from ctypes import *

file_path = "Z:/Desktop/map_infmation/map_date/2023_8_21.csv"
plannerDLL=cdll.LoadLibrary("./dll/libRouting_oldd.dll")
# pdll = CDLL(os.path.abspath('C:/Users/LUxy/Desktop/moveDLL/build/libRouting_oldd.dll')).FILEPATH(bytes(file_path, encoding='utf8'))
x=8887
s="10.211.55.4"
plannerDLL.SETUDP(x,bytes(s,encoding='utf-8'))
plannerDLL.FILEPATH(bytes(file_path, encoding='utf8'))

# 输入搜索分辨率
plannerDLL.PreStart(c_double(1))
# 车长，车宽
plannerDLL.UpDateVehicleStructureInfo.argtypes = (c_double,c_double)
plannerDLL.UpDateVehicleStructureInfo(2.0,2.0)
# 车最大前向速度，最大反向速度，最大前向加速度，最大反向加速度，最大转角
plannerDLL.UpdateVehiclePerformanceInfo.argtypes = (c_double,c_double,c_double,c_double,c_double)
plannerDLL.UpdateVehiclePerformanceInfo(20.0,1.0,5.0,1.0,45)
# 起始点x，y终点x，y
plannerDLL.start.argtypes = (c_double,c_double,c_double,c_double)
plannerDLL.start(69.0035,-15.9217,852.3719,803.6022)


